home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DOpus Plus
/
DOpus Plus.iso
/
Tutorial
/
C Guide
/
Simple_Module2
/
IPCWindow
/
smakefile
< prev
Wrap
Makefile
|
1998-09-01
|
3KB
|
106 lines
# Makefile for a sample Opus 5 module
# This is based on the structure of the real Opus makefile, but may be
# adapted as you see fit
# It's now a little bit tricky, here is needed that all files from the
# parent directory have the right date
# Declare some variables, so we must not change multiple lines
# Object files for this module
EXAMPLEOBJS = modinit.o /ModuleEntry.o /ExampleRequest.o IPCWindow.o /HiddenCommand.o /buildinstrings.o
# You should always have the modinit.o on the first place. After this
# there should be your file with the L_ModuleEntry() function. All other
# may follow like you want...
# Library-Name/-Version/-Revision
# use only lowercase for the name of the module
MODULENAME = example.module
EXAMPLEVER = 56
EXAMPLEREV = 0
# Compiler options
CCOPTS = noversion optimize
# Linker options
SLINKOPTS = noicons smallcode smalldata
#######################################################################
# If you have "ALL" in the tooltypes of your "Build" icon, this objects
# will be created...
ALL: /includes/buildin.strings $(MODULENAME)
#######################################################################
# Note to the line starting with "lib" :
# The last entry is an object library created by Dirk Stoecker. This
# does supply some replacements for the string.h and some other stuff
# (in conclusion with sdi_std.h)
# This results in smaller code. It is your choice ...
# If you don't want use it, delete "lib:sdi_std.lib", but you must
# include instead the "string.h" (if you need their functions).
# Do not modify other stuff here !!!
$(MODULENAME): $(EXAMPLEOBJS) smakefile scoptions
slink with <<
libprefix _L_
libfd /modules.fd
from lib:libent.o lib:libinit.o $(EXAMPLEOBJS)
to $@
lib lib:sc.lib lib:amiga.lib lib:dopuslib.lib //sc/lib/sdi_std.lib
libversion $(EXAMPLEVER)
librevision $(EXAMPLEREV)
$(SLINKOPTS)
<
#######################################################################
modinit.o: modinit.c
#
IPCWindow.o: IPCWindow.c /includes/Window.h /includes/Project.h /includes/buildin.strings
#######################################################################
# Build what from what and how...
.c.o:
sc $(CCOPTS) $*.c
.asm.o:
sc:c/asm -iASMINC: $*.asm
.cd.strings:
catcomp descriptor=$*.cd cfile=$*.strings
#######################################################################
# Done only if the tooltype CLEAN is supplied ...
clean:
delete ~(\#?_strings).o quiet
copy *.module DOpus5:modules
setdate \#?.cd
#######################################################################
# My choice :-) (, but first "ALL" )
copy:
copy *.module DOpus5:modules
wait 5
avail flush
#######################################################################